

class DatabaseService(object):
    # no doc
    def check_member_in_room(self, room_id, member_id): # reliably restored by inspect
        # no doc
        pass

    def check_new_messages(self): # reliably restored by inspect
        """ 遍历所有消息数据库，检查并返回新消息。 """
        pass

    def execute_query(self, db_path, query, params='()'): # reliably restored by inspect
        """ 使用“即用即连”模式执行只读SQL查询。 """
        pass

    def get_all_db_files(self): # reliably restored by inspect
        """ 获取所有数据库文件路径 """
        pass

    def get_contact_by_display_name(self, display_name): # reliably restored by inspect
        """ 通过display_name模糊搜索联系人信息 """
        pass

    def get_contact_by_sender_id(self, sender_id, message_db_path=None): # reliably restored by inspect
        """ 通过发送者ID获取联系人信息 """
        pass

    def get_contact_by_username(self, username, refresh=True): # reliably restored by inspect
        """ 通过username获取联系人信息。 """
        pass

    def get_db_path_by_username(self, username): # reliably restored by inspect
        """ 通过username获取其主要消息数据库路径。 """
        pass

    def get_db_tables(self, db_path): # reliably restored by inspect
        """ 获取数据库中的所有表名。 """
        pass

    def get_emoji_url(self, md5, thumb=False): # reliably restored by inspect
        """ 获取表情包的CDN URL。 """
        pass

    def get_file(self, md5): # reliably restored by inspect
        """ 获取普通文件的相对路径。 """
        pass

    def get_file_by_md5(self, md5): # reliably restored by inspect
        # no doc
        pass

    def get_fmessage_list(self): # reliably restored by inspect
        """ 查询好友请求列表。 """
        pass

    def get_image(self, xml_content, message, up_dir=None, md5=None, thumb=False, sender_wxid=None): # reliably restored by inspect
        """ 获取图片文件的相对路径。 """
        pass

    def get_image_by_md5(self, md5): # reliably restored by inspect
        # no doc
        pass

    def get_image_by_time(self, message, sender_wxid): # reliably restored by inspect
        """ 通过时间规则推算图片相对路径，并返回最可能存在的那个。 """
        pass

    def get_image_thumb(self, message, sender_wxid): # reliably restored by inspect
        """ 获取图片缩略图的相对路径。 """
        pass

    def get_messages_by_username(self, username, count=10, order=None): # reliably restored by inspect
        """ 根据用户名获取其最近的消息。 """
        pass

    def get_message_by_server_id(self, server_id, message_db_path, username): # reliably restored by inspect
        """ 通过server_id获取消息 """
        pass

    def get_room_by_md5(self, username_md5): # reliably restored by inspect
        """ 通过群聊username的MD5值反向查询群聊信息。 """
        pass

    def get_room_member_count_by_name(self, room_name): # reliably restored by inspect
        # no doc
        pass

    def get_room_member_list(self, room_user_name): # reliably restored by inspect
        """ 获取群聊成员列表，包含群内昵称。 """
        pass

    def get_video(self, md5, thumb=False): # reliably restored by inspect
        """ 获取视频文件的相对路径。 """
        pass

    def get_video_by_md5(self, md5): # reliably restored by inspect
        # no doc
        pass

    def load_chat_rooms(self): # reliably restored by inspect
        """ 从contact数据库加载所有群聊信息并缓存。 """
        pass

    def load_message_username_map(self): # reliably restored by inspect
        """ 构建username到其所在message_db路径的映射缓存。 """
        pass

    def query_text_messages(self, username, limit=10, start_timestamp=None, end_timestamp=None, order=None, query=None): # reliably restored by inspect
        # no doc
        pass

    def setup(self): # reliably restored by inspect
        """ 初始化数据库服务，加载所有必要的路径、密钥和初始数据。 """
        pass

    def _connect_db(*args, **kwds): # reliably restored by inspect
        """
        上下文管理器，用于按需创建、解密并提供数据库游标。
                在退出上下文时自动关闭连接，确保无资源泄露。
        """
        pass

    def _get_db_key(self, db_path): # reliably restored by inspect
        """
        高效获取或生成并缓存指定数据库的解密密钥。
                检查本地字典缓存 -> 检查UserService持久化缓存 -> 计算并更新所有缓存。
        """
        pass

    def _get_emoji_info(self, md5): # reliably restored by inspect
        # no doc
        pass

    def _get_room_member_nickname(self, room_username): # reliably restored by inspect
        """ 查询群成员在群内的昵称。 """
        pass

    def _initialize_msg_sequence(self): # reliably restored by inspect
        """ 初始化所有消息表的序列号，用于后续新消息检测。 """
        pass

    def _init_db_paths(self): # reliably restored by inspect
        """ 初始化所有数据库文件的绝对路径。 """
        pass

    def _load_db_timestamps(self): # reliably restored by inspect
        """ 加载每个消息数据库的起始时间戳。 """
        pass

    def _normalize_key(self, key): # reliably restored by inspect
        """ 规范化密钥格式。 """
        pass

    def __init__(self, user_service): # reliably restored by inspect
        """
        初始化微信数据库解析器。
        所有数据库连接都以只读模式按需创建，并在使用后立即释放。
        """
        pass

    __weakref__ = property(lambda self: object(), lambda self, v: None, lambda self: None)  # default
    """list of weak references to the object"""


    __dict__ = None # (!) real value is "mappingproxy({'__module__': 'omni_bot_sdk.services.core.database_service', '__init__': <compiled_function DatabaseService.__init__ at 0x00000212D2EAAE40>, 'setup': <compiled_function DatabaseService.setup at 0x00000212D2EAA940>, '_connect_db': <function DatabaseService._connect_db at 0x00000212D0A77240>, '_normalize_key': <compiled_function DatabaseService._normalize_key at 0x00000212D2EAAF40>, '_get_db_key': <compiled_function DatabaseService._get_db_key at 0x00000212D2EAB040>, '_init_db_paths': <compiled_function DatabaseService._init_db_paths at 0x00000212D2EAB140>, '_load_db_timestamps': <compiled_function DatabaseService._load_db_timestamps at 0x00000212D2EAB240>, '_initialize_msg_sequence': <compiled_function DatabaseService._initialize_msg_sequence at 0x00000212D2EAB340>, 'execute_query': <compiled_function DatabaseService.execute_query at 0x00000212D2EAB440>, 'get_db_path_by_username': <compiled_function DatabaseService.get_db_path_by_username at 0x00000212D2EAB540>, 'get_all_db_files': <compiled_function DatabaseService.get_all_db_files at 0x00000212D2EAB640>, 'get_db_tables': <compiled_function DatabaseService.get_db_tables at 0x00000212D2EAB740>, 'check_new_messages': <compiled_function DatabaseService.check_new_messages at 0x00000212D2EAB840>, 'get_message_by_server_id': <compiled_function DatabaseService.get_message_by_server_id at 0x00000212D2EAB940>, 'get_contact_by_username': <compiled_function DatabaseService.get_contact_by_username at 0x00000212D2EABA40>, 'get_contact_by_sender_id': <compiled_function DatabaseService.get_contact_by_sender_id at 0x00000212D2EABB40>, 'get_contact_by_display_name': <compiled_function DatabaseService.get_contact_by_display_name at 0x00000212D2EABC40>, 'load_chat_rooms': <compiled_function DatabaseService.load_chat_rooms at 0x00000212D2EABD40>, 'load_message_username_map': <compiled_function DatabaseService.load_message_username_map at 0x00000212D2EABE40>, 'get_room_by_md5': <compiled_function DatabaseService.get_room_by_md5 at 0x00000212D2F4C040>, 'get_image_by_md5': <compiled_function DatabaseService.get_image_by_md5 at 0x00000212D2F4C140>, 'get_video_by_md5': <compiled_function DatabaseService.get_video_by_md5 at 0x00000212D2F4C240>, 'get_file_by_md5': <compiled_function DatabaseService.get_file_by_md5 at 0x00000212D2F4C340>, 'get_video': <compiled_function DatabaseService.get_video at 0x00000212D2F4C440>, 'get_image': <compiled_function DatabaseService.get_image at 0x00000212D2F4C540>, 'get_image_thumb': <compiled_function DatabaseService.get_image_thumb at 0x00000212D2F4C640>, 'get_image_by_time': <compiled_function DatabaseService.get_image_by_time at 0x00000212D2F4C740>, 'get_file': <compiled_function DatabaseService.get_file at 0x00000212D2F4C840>, 'get_emoji_url': <compiled_function DatabaseService.get_emoji_url at 0x00000212D2F4C940>, '_get_emoji_info': <compiled_function DatabaseService._get_emoji_info at 0x00000212D2F4CA40>, 'get_room_member_list': <compiled_function DatabaseService.get_room_member_list at 0x00000212D2F4CB40>, '_get_room_member_nickname': <compiled_function DatabaseService._get_room_member_nickname at 0x00000212D2F4CC40>, 'get_room_member_count_by_name': <compiled_function DatabaseService.get_room_member_count_by_name at 0x00000212D2F4CD40>, 'check_member_in_room': <compiled_function DatabaseService.check_member_in_room at 0x00000212D2F4CE40>, 'get_fmessage_list': <compiled_function DatabaseService.get_fmessage_list at 0x00000212D2F4CF40>, 'get_messages_by_username': <compiled_function DatabaseService.get_messages_by_username at 0x00000212D2F4D040>, 'query_text_messages': <compiled_function DatabaseService.query_text_messages at 0x00000212D2F4D140>, '__dict__': <attribute '__dict__' of 'DatabaseService' objects>, '__weakref__': <attribute '__weakref__' of 'DatabaseService' objects>, '__doc__': None})"

